<template>
  <div>
    <!-- 轮播图 -->
    <mt-swipe :auto="4000">
      <mt-swipe-item v-for="(item, i) in lunbolist" :key="i">
        <img :src="item.img" alt="">
      </mt-swipe-item>
    </mt-swipe>
    <!-- 九宫格 到 6宫格 的改造工程 -->
    <ul class="mui-table-view mui-grid-view mui-grid-9">
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/newsList">
          <img src="../../images/menu1.png" alt="">
          <div class="mui-media-body">新闻资讯</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/photoList">
          <img src="../../images/menu2.png" alt="">
          <div class="mui-media-body">图片分享</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="/home/goodsList">
          <img src="../../images/menu3.png" alt="">
          <div class="mui-media-body">狐狸影视</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="#">
          <img src="../../images/menu4.png" alt="">
          <div class="mui-media-body">留言反馈</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="#">
          <img src="../../images/menu5.png" alt="">
          <div class="mui-media-body">视频专区</div>
        </router-link>
      </li>
      <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
        <router-link to="#">
          <img src="../../images/menu6.png" alt="">
          <div class="mui-media-body">联系我们</div>
        </router-link>
      </li>
    </ul>
  </div>
</template>

<script>
export default {
  data() {
    return {
      // message: ''
      lunbolist: [
        { img: 'https://i8.mifile.cn/v1/a1/2865cbe6-a603-2818-fe65-bc4f78afc923!720x360.webp', url: 'https://m.mi.com' },
        { img: 'https://i8.mifile.cn/v1/a1/64837c60-1ec4-c71a-f6d2-9026845713fd!720x360.webp', url: 'https://m.mi.com' },
        { img: 'https://i8.mifile.cn/v1/a1/f50dcc17-86ca-d095-8a25-255786b37fab!720x360.webp', url: 'https://m.mi.com' }
      ]
    }
  },
  created() {
    // this.getPic()
  },
  methods: {
    // getPic() { // 找不到合适的图片数据接口, 用了固定数据
    //   this.$http.jsonp('https://cn.bing.com/HPImageArchive.aspx?format=js&idx=0&n=1')
    //     .then(result => {
    //       console.log(result)
    //     })
    // }
  }
}
</script>

<style lang="scss" scoped>
.mint-swipe {
  height: 190px;
  .mint-swipe-item {
    &:nth-child(1) {
      background-color: red;
    }
    &:nth-child(2) {
      background-color: blue;
    }
    &:nth-child(3) {
      background-color: cyan;
    }
    img {
      width: 100%;
      height: 100%;
    }
  }
}
.mui-grid-view.mui-grid-9 {
  background-color: #fff;
  border: none;
  img {
    width: 60px;
    height: 60px;
  }
  .mui-media-body {
    font-size: 13px;
  }
  .mui-table-view-cell {
    border: 0;
  }
}
</style>
